<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<div class="pageContent">
	<form method="post" action="${rootUrl}/goods/brand-goods-class/${brandGoodsClass.id}" class="pageForm required-validate" onsubmit="return beforeSubmit(this);">
		 <c:if test="${brandGoodsClass.id != 0 && brandGoodsClass.id != '' }"><input type="hidden" name="_method" value="put"></c:if>
		<input type="hidden" name="goodsClassId" value="${goodsClass.id }"> 
		<div class="pageFormContent" layoutH="56">
			<p>
			     <label>商品类别名称：</label>
				<input name="brandGoodsClass.goodsClassName" class="required" type="text" size="30" value="${goodsClass.name }" />
			</p>
			<p>
				<label>品牌名称：</label>
				<input id="brandId" name="brand.id" type="hidden" size="30" value="${brandGoodsClass.brand.id}" />
				<input type="text" style="float:left" id="brandName" name="brand.name" class="required" value="${brandGoodsClass.brand.name}">
				<a class="btnLook" href="${rootUrl}/goods/brand/1/dialog?id=${brandGoodsClass.brand.id}" width="800" height="720" lookupGroup="brand">品牌类别</a>
			</p>
   		 </div>
    	<div class="formBar">
			<ul>
				<li><div class="buttonActive"><div class="buttonContent"><button id="theSubmit" type="submit">保存</button></div></div></li>
				<li>
					<div class="button"><div class="buttonContent"><button type="button" class="close">取消</button></div></div>
				</li>
			</ul>
		</div>
    </form>
<script>
	function beforeSubmit(obj){
		$("#brandName").attr("name","brandGoodsClass.brandName");
		return validateCallback(obj, newDialogAjaxDone);
	}
</script>